<?php

$redisclient = new swoole_redis;

$redisclient->connect('127.0.0.1', 6379,function(swoole_redis $swooleClient,$result){
	echo "connect".PHP_EOL;
	
	var_dump($result);
	
	// 同步设置  (new Redis())->set('key',2)
	/**
	$swooleClient->set("fwz1",time(),function(swoole_redis $swooleClient,$result){
		var_dump($result);
	});
	
	
	$swooleClient->get("fwz1",function(swoole_redis $swooleClient,$result){
		var_dump($result);
	});
	*/
	
	
	$swooleClient->keys("*",function(swoole_redis $swooleClient,$result){
		var_dump($result);
	});
	
	$swooleClient->close();
	
});
